package com.zipking.cloud.springbootmybatis.util;

import com.zipking.cloud.springbootmybatis.model.MyEntity;

import java.util.List;
import java.util.stream.Collectors;

public class MyEntityProcessor implements AsyncBatchProcessorService.BatchProcessor<MyEntity, String> {
    @Override
    public List<String> processBatch(List<MyEntity> batch) {
        return batch.stream()
                .map(MyEntity::getData)
                .collect(Collectors.toList());
    }
}